﻿using System;
using System.Collections.Generic;
using System.Data;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using Xejen.Database.Entities;

namespace Xejen.Database.Dapper
{
    /// <summary>
    /// <inheritdoc cref="DapperRepositoryBase{TDbContext, TEntity, TPrimaryKey}"/>，主键id默认使用<see langword="long"/>
    /// </summary>
    /// <typeparam name="TDbContext"><inheritdoc/></typeparam>
    /// <typeparam name="TEntity"><inheritdoc/></typeparam>
    public class DapperRepository<TDbContext, TEntity> : DapperRepository<TDbContext, TEntity, long>, IRepository<TEntity, long>
        where TEntity : class, IEntity<long>
        where TDbContext : IDbConnection
    {
        /// <inheritdoc cref="DapperRepository{TDbContext, TEntity}"/>
        /// <param name="dbContextProvider"><inheritdoc/></param>
        public DapperRepository(IDbContextProvider<TDbContext> dbContextProvider)
            : base(dbContextProvider)
        {
        }
    }
}
